<!DOCTYPE html>
<!-- saved from url=(0022)http://www.hasbei.com/ -->
<html lang="en" xmlns:th="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link rel="stylesheet" href="/css/reset.css">
    <link rel="stylesheet" href="/css/commone.css">
    <link rel="stylesheet" href="/css/amazeui.min.css">
    <link rel="stylesheet" href="/css/amazeui.cropper.css">
    <link rel="stylesheet" href="/css/custom_up_img.css">

    <link rel="stylesheet" media="screen and (min-width:481px)" href="/css/usercenter.css">
    <link rel="stylesheet" media="screen and (max-width:480px)" href="/css/usercenter(1).css">
    <script src="/js/hm.js"></script>
    <script src="/js/hm(1).js"></script>
    <script type="text/javascript">var basePath = "/";</script>
    <script src="/js/common.js"></script>
    <script src="/js/jquery-3.5.1.min.js"></script>
    <script src="/js/footfixed.js"></script>
    <script src="/js/layer.js"></script>
    <script src="/js/amazeui.min.js"></script>
    <script src="/js/cropper.min.js"></script>
    <script src="/js/custom_up_img.js"></script>
    <link rel="stylesheet" href="/css/layer.css" id="layuicss-layer">
    <title>站内消息</title></head>
<body rlt="1" style="">
<div class="content">
    <div th:include="/user_page/usercenter_head :: usercenterhead"></div>
    <div class="content-main">
        <div class="main-info">
            <div th:include="/user_page/usercenter_left :: left"></div>

            <div class="main-user-right">
                <div class="user-right-top">
                    <ul>
                        <li class="select-active" id="dy"><a href="javascript:;" >站内消息</a></li>
                    </ul>
                </div>
                <div class="user-right-action">
                    <div id="myContent">
                        <div class="action-item" id="item465" th:each="mesg:${msgList}">

                            <div class="action-item-title">
                                <a href="javascript:;" target="_self" id="465">[[${mesg.title}]]</a>
                            </div>
                            <div class="ansower-content">

                                <a href="javascript:;" target="_self" id="465" th:if="${mesg.checkType} eq 2">发布内容：[[${mesg.content}]]</a>
                                <a href="javascript:;" target="_self" id="465" th:if="${mesg.checkType} eq 1">回复内容：[[${mesg.content}]]</a>
                                <br>
                                <span th:if="${mesg.checkState} eq 1">审核状态：审核中</span>
                                <span th:if="${mesg.checkState} eq 2">审核状态：<span  style="color: green">审核通过</span>></span>
                                <span th:if="${mesg.checkState} eq -1">审核状态：<span style="color: red">审核未通过</span></span>
                                <br>
                                <span th:if="${mesg.checkDescribe}">审核描述：[[${mesg.checkDescribe}]]</span>
                            </div>
                            <div class="ansower-share-setting">
                                <div class="ansower-share">
                                    <a href="javascript:;" target="_self" onclick="" id="465">
                                        <span th:if="${mesg.checkType} eq 1">[文章审核]</span>
                                        <span th:if="${mesg.checkType} eq 2">[问题审核]</span>
                                        <span th:if="${mesg.checkType} eq 3">[回答审核]</span>
                                    </a>
                                    <a href="#" target="_self" id="465">
                                        <span>[[${mesg.CheckTime}]]</span>
                                    </a>
                                    <a href="javascript:;" target="_self">
                                        <span >
                                            <a href="#" style="color: red">未读</a>
                                        </span>
                                    </a>
                                    <!-- <div style="margin-top: -2px;"> <a href=""><img src="images/icon_Share.png" alt="有贝口腔网"><span>分享</span></a> </div> -->
                                </div>
                            </div>
                        </div>
                        <div class="more-content">
                            <div class="load-more" style="display:none">
                                <img src="/img/load-more.gif">
                                <span>加载中</span>
                            </div>
                            <div class="load-more-two" style="display:none" onclick="moreList()">点击加载更多</div>
                            <div class="no-data" style="display:none">┭┮﹏┭┮,没有数据啦</div>
                        </div>
                    </div>
                     </div>
                </div>
            </div>
        </div>
    </div>
    <div th:include="/user_page/usercenter_footer :: footer"></div>
    <script>
        var _hmt = _hmt || [];
        (function () {
            var hm = document.createElement("script");
            hm.src = "https://hm.baidu.com/hm.js?4245936cbef31e434e2b387b56dfd7d8";
            var s = document.getElementsByTagName("script")[0];
            s.parentNode.insertBefore(hm, s);
        })();
    </script>
</div>
<script>function delDy(obj) {/*删除动态*/
    var id = $(obj).attr("id");
    layer.confirm('你确定要删除吗,删除后不可恢复哦？', {btn: ['确定', '取消']}, function () {
        $.post(basePath + "user/center/dy/del?id=" + id, function (data) {
            if (data.success) {
                layer.msg("删除成功");
                $("#item" + id).remove();
            } else {
                layer.msg(data.msg);
            }
        });
    }, function () {
    });
}

function delQa(obj) { /*删除问题*/
    var id = $(obj).attr("id");
    layer.confirm('你确定要删除吗,删除后不可恢复哦？', {btn: ['确定', '取消']}, function () {
        $.post(basePath + "user/center/qa/del?no=" + id, function (data) {
            if (data.success) {
                layer.msg("删除成功");
                $("#item" + id).remove();
            } else {
                layer.msg(data.msg);
            }
        });
    }, function () {
    });
}
function delQaReply(obj) { /*删除回答*/
    var id = $(obj).attr("id");
    layer.confirm('你确定要删除吗,删除后不可恢复哦？', {btn: ['确定', '取消']}, function () {
        $.post(basePath + "user/center/qaReply/del?id=" + id, function (data) {
            if (data.success) {
                layer.msg("删除成功");
                $("#item" + id).remove();
            } else {
                layer.msg(data.msg);
            }
        });
    }, function () {
    });
}
function editQaReply(obj) { /*编辑回答*/
    var id = $(obj).attr("id");
    layer.open({
        type: 2,
        title: "编辑回答",
        shadeClose: false,
        area: ['900px', '600px'],
        fixed: true,
        maxmin: false,
        scrollbar: false,
        content: basePath + 'user/center/qaReply/edit/' + id
    });
}
function delCollect(obj) { /*删除回答*/
    var id = $(obj).attr("id");
    layer.confirm('你确定要删除吗,删除后不可恢复哦？', {btn: ['确定', '取消']}, function () {
        $.post(basePath + "user/collect/del?id=" + id, function (data) {
            if (data.success) {
                layer.msg("删除成功");
                $("#item" + id).remove();
            } else {
                layer.msg(data.msg);
            }
        });
    }, function () {
    });
}
function delArt(obj) { /*删除文章*/
    var id = $(obj).attr("id");
    layer.confirm('你确定要删除吗,删除后不可恢复哦？', {btn: ['确定', '取消']}, function () {
        $.post(basePath + "user/center/article/del?no=" + id, function (data) {
            if (data.success) {
                layer.msg("删除成功");
                $("#item" + id).remove();
            } else {
                layer.msg(data.msg);
            }
        });
    }, function () {
    });
}
function editArt(obj) { /*删除文章*/
    var id = $(obj).attr("id");
    layer.open({
        type: 2,
        title: "编辑文章",
        shadeClose: false,
        area: ['900px', '600px'],
        fixed: true,
        maxmin: false,
        scrollbar: false,
        content: basePath + 'user/center/article/edit/' + id
    });
}
var current = 1;
var tabId = "";/*动态数据*/
function dyList() {
    $(".load-more-two").show();
    $(".load-more").hide();/*如果没有数据了就隐藏*/

}/*提问数据*/
function qaList() {
    $(".load-more").show();
    $(".load-more-two").hide();
    $.post(basePath + "user/center/qalist?current=" + current, function (data) {
        $(".load-more").hide();/*如果没有数据了就隐藏*/
        if (data.length == 0) {
            $(".load-more-two").hide();
            if (current == 1) {
                $(".no-data").show();
            }
        } else {
            $(".load-more-two").show();
            $("#myContent").append(data);
        }
    });
}/*回答数据列表*/
function qaReplyList() {
    $(".load-more").show();
    $(".load-more-two").hide();
    $.post(basePath + "user/center/qaReplylist?current=" + current, function (data) {
        $(".load-more").hide();/*如果没有数据了就隐藏*/
        if (data.length == 0) {
            $(".load-more-two").hide();
            if (current == 1) {
                $(".no-data").show();
            }
        } else {
            $(".load-more-two").show();
            $("#myContent").append(data);
        }
    });
}/*收藏数据列表*/
function collectList() {
    $(".load-more").show();
    $(".load-more-two").hide();
    $.post(basePath + "user/center/collectList?current=" + current, function (data) {
        $(".load-more").hide();/*如果没有数据了就隐藏*/
        if (data.length == 0) {
            $(".load-more-two").hide();
            if (current == 1) {
                $(".no-data").show();
            }
        } else {
            $(".load-more-two").show();
            $("#myContent").append(data);
        }
    });
}/*收藏数据列表*/
function articleList() {
    $(".load-more").show();
    $(".load-more-two").hide();
    $.post(basePath + "user/center/articlelist?current=" + current, function (data) {
        $(".load-more").hide();/*如果没有数据了就隐藏*/
        if (data.length == 0) {
            $(".load-more-two").hide();
            if (current == 1) {
                $(".no-data").show();
            }
        } else {
            $(".load-more-two").show();
            $("#myContent").append(data);
        }
    });
}

function loadTabList() {
    if (tabId == 'dy') {/*动态*/
        dyList();
    } else if (tabId == 'an') {/* 回答*/
        qaReplyList();
    } else if (tabId == 'q') {/* 提问*/
        qaList();
    } else if (tabId == 'col') {/* 收藏*/
        collectList();
    } else if (tabId == 'art') {/* 文章*/
        articleList();
    }
}/*加载更多*/
function moreList() {
    // current++;
    // loadTabList();
    $(".load-more-two").hide();
    $(".no-data").show();
}

function initList() {
    tabId = 'dy';/*动态*/
    dyList();
}

initList();//初始化 /*重新加载从第一页开始*/
$(function(){
    initPageEvFun();
});
function initPageEvFun(){
    /*点击tab标签*/
    $(".user-right-top li").click(function(){
        var id=$(this).attr("id");
        if(id==tabId){ return ;
        }
        tabId=id;
        //initListPage1();
        $("li").removeClass("select-active");
        $(this).addClass("select-active");
    })
    $(".change-info-show").hide();
    $(".change-info-btn").click(function(){
        $(".change-info-top").hide();
        $(".change-info-show").show();
    })
    $(".write-box-input").change(function(){
        var inputle = $(this).val().length;
        $(".write-box-span i").text(inputle);
    })
    $(".write-box-textarea").change(function(){
        var textareale = $(this).val().length;
        $(".write-box-right i").text(textareale);
    })
    $(".write-box-input").focus(function(){
        $(this).parent().css("border-color","rgba(41,167,230,1)");
    })
    $(".write-box-input").blur(function(){
        $(this).parent().css("border-color","#ddd");
    })
    $(".write-box-textarea").focus(function(){
        $(this).parent().css("border-color","rgba(41,167,230,1)");
    })
    $(".write-box-textarea").blur(function(){
        $(this).parent().css("border-color","#ddd");
    })
    $(".sure-btn").click(function(){
        var inputval = $(".write-box-input").val();
        var textareaval =$(".write-box-textarea").val();
        if(inputval == "" || textareaval == ""){ alert("请输入信息");
        return false;
        }
        $(".h3-name").text(inputval); $(".p-style").text(textareaval);
        $(".change-info-show").hide();
        $(".change-info-top").show();
    })
    $(".close-btn").click(function(){
        $(".change-info-show").hide();
        $(".change-info-top").show();
    })
}</script>
<div class="xl-chrome-ext-bar" id="xl_chrome_ext_{4DB361DE-01F7-4376-B494-639E489D19ED}" style="display: none;">
    <div class="xl-chrome-ext-bar__logo"></div>
    <a id="xl_chrome_ext_download" href="javascript:;" class="xl-chrome-ext-bar__option">下载视频</a><a
        id="xl_chrome_ext_close" href="javascript:;" class="xl-chrome-ext-bar__close"></a></div>
<div id="qds" style="display:none;"></div>
</body>
</html>